const list=[
    {
        id:1,
        name:"小明",
        gender:'男',
        age:20
    },
    {
        id:2,
        name:"小张",
        gender:'男',
        age:24
    },
    {
        id:3,
        name:"小画",
        gender:'女',
        age:21
    },
    {
        id:4,
        name:"猪小明",
        gender:'男',
        age:30
    }
]

const results=list.filter(item=>{
     return item.gender==='男'
})

console.log(results)